
import javax.swing.SwingConstants;
import cytoscape.Cytoscape;
import cytoscape.plugin.CytoscapePlugin;
import cytoscape.view.CytoscapeDesktop;
import cytoscape.view.cytopanels.CytoPanel;

/******************************************************************************
 * A class required to activate the plugin in cytoscape. 
 * @author liatperl
 * Last Updater: Liat
 * Date: 20.8.09
 ******************************************************************************/

public class EnrichmentPlugin extends CytoscapePlugin {
	
	
	/**
	 * Constructor.
	 */
	public EnrichmentPlugin() {
		
		CytoscapeDesktop desktop = Cytoscape.getDesktop();
        CytoPanel cytoPanel = desktop.getCytoPanel(SwingConstants.WEST);
        EnrichmentPanel enrPanel = new EnrichmentPanel();
        cytoPanel.add("GO Enrichment",enrPanel);
	}

	
	/**
	 * Does the operations the result from selecting the enrichment plugin.
	 * @author liatperl
	 */
	/*
	public class EnrichmentAction extends CytoscapeAction{

		
		/**
		 * Constructor
		 */
	/*
		public EnrichmentAction() {
			super("Functional Enrichment");
		}
		
		
		/**
		 * Creates the GUI once the user selected the enrichment plugin.
		 * @param arg0
		 */
		/*
		public void actionPerformed(ActionEvent arg0) {
			CyNetwork network = Cytoscape.getCurrentNetwork();
            //get the network view object
            CyNetworkView view = Cytoscape.getCurrentNetworkView();
            //can't continue if either of these is null
            if (network == null || view == null) 
            	return;
            _gui.setVisible(true); // start the gui.
		}

	}
*/	
}
